home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1998 January: Mac OS SDK / Dev.CD Jan 98 SDK2.toast / Development Kits (Disc 2) / QuickDraw GX / Programming Stuff / Sample Code / Printing Samples / Printer Drivers… / CustomWriterGX / NewApp.a < prev    next >
Encoding:
Text File  |  1996-03-20  |  3.4 KB  |  93 lines  |  [TEXT/MPS ]

  1. ;------------------------------------------------------------------------------
  2. ;
  3. ;    FILENAME
  4. ;        NewApp.a
  5. ;
  6. ;    DESCRIPTION
  7. ;        Contains the jump table for all of the messages we override except
  8. ;        the old-application compatibility ones.
  9. ;
  10. ;    COPYRIGHT
  11. ;        Copyright © 1995 Apple Computer, Inc.
  12. ;        All rights reserved.
  13. ;    
  14. ;    Modification history
  15. ;        10/04/95 - David Hayward -    Version 1.0.4 modified code so that
  16. ;                                    the driver can be build under MPW,
  17. ;                                    Metrowerks, and Symantec.  In general,
  18. ;                                    all that was required to do this was 
  19. ;                                    to add an inline-assembly jumptable
  20. ;                                    and to store all globals off of the
  21. ;                                    message manager instance context.
  22. ;                                    Also made a few changes so that the
  23. ;                                    driver can be rebuilt to support any
  24. ;                                    resolution by changing the #defines
  25. ;                                    kResolution and kPatStretch in
  26. ;                                    "CommonDefines.h"
  27. ;
  28. ;        06/14/95 - Dave Hersey -    Version 1.0.3 to fix a bug in
  29. ;                                    CustomBufferingAndIO.c when creating
  30. ;                                    high-res PICTs, and to make the size
  31. ;                                    of buffers more flexible.
  32. ;
  33. ;        05/26/95 - Dave Hersey -    Version 1.0.2 to add the new 'outp'
  34. ;                                    desktop printer resource in NewApp.c.
  35. ;
  36. ;        05/03/95 - Dave Hersey -    Version 1.0.1 to fix some minor bugs in
  37. ;                                    CustomBufferingAndIO.c.
  38. ;
  39. ;        01/14/95 - Dave Hersey -    Created from the shell of a hollowed-out
  40. ;                                    ImageWriter driver.
  41. ;
  42. ;--------------------------------------------------------------------------------
  43.  
  44.                 CASE    OBJ
  45.                 STRING    ASIS
  46.  
  47.     EXPORT    SD_JumpTable
  48.     IMPORT    SD_RasterDataIn                ; Our override for GXRasterDataIn.
  49.     IMPORT    SD_ImageJob                    ; Our override for GXImageJob.
  50.     IMPORT    SD_StartSendPage            ; Our override for GXStartSendPage.
  51.     IMPORT    SD_FinishSendPage            ; Our override for GXFinishSendPage.
  52.     IMPORT    SD_SetupImageData            ; Our override for GXSetupImageData.
  53.     IMPORT    SD_OpenConnection            ; Our override for GXOpenConnection.
  54.     IMPORT    SD_CloseConnection            ; Our override for GXCloseConnection.
  55.     IMPORT    SD_CleanupOpenConnection    ; Our override for GXCleanupOpenConnection.
  56.     IMPORT    SD_BufferData                ; Our override for GXBufferData.
  57.     IMPORT    SD_FreeBuffer                ; Our override for GXFreeBuffer.
  58.     IMPORT    SD_WriteData                ; Our override for GXWriteData.
  59.     IMPORT    SD_DumpBuffer                ; Our override for GXDumpBuffer.
  60.     IMPORT    SD_DefaultDesktopPrinter    ; Our override for GXDefaultDesktopPrinter.
  61.  
  62. ;--------------------------------------------------------------------------------
  63. ;    This code must be kept in sync with the assembly jump table
  64. ;    in NewApp.c and the gxOverrideType resources in NewApp.r
  65. ;--------------------------------------------------------------------------------
  66.  
  67. SD_JumpTable    PROC                    ; Our main entry point.
  68.     
  69.             DC.L    0                    ; Reserved for owner count.
  70.  
  71.     ; Raster messages
  72.             JMP SD_RasterDataIn                    ; (offset =  4)
  73.  
  74.     ; Universal messages
  75.             JMP SD_ImageJob                        ; (offset =  8)
  76.             JMP SD_StartSendPage                ; (offset =  12)
  77.             JMP SD_FinishSendPage                ; (offset =  16)
  78.             JMP SD_SetupImageData                ; (offset =  20)
  79.             JMP SD_OpenConnection                ; (offset =  24)
  80.             JMP SD_CloseConnection                ; (offset =  28)
  81.             JMP SD_CleanupOpenConnection        ; (offset =  32)
  82.             JMP SD_BufferData                    ; (offset =  36)
  83.             JMP SD_FreeBuffer                    ; (offset =  40)
  84.             JMP SD_WriteData                    ; (offset =  44)
  85.             JMP SD_DumpBuffer                    ; (offset =  48)
  86.             JMP SD_DefaultDesktopPrinter        ; (offset =  52)
  87.  
  88.             RTS                            ; this is here so that the
  89.                                         ; entrypoint will be labled "Anon0"
  90.  
  91.             ENDPROC
  92.     END
  93.